using System;
using UnityEngine;

public static class DebugUtils
{
    public static string WithColor(this string message, string color) => $"<color={color}> {message}</color>";
    
    public static string WithColor(this string message, LogColor color) => $"<color={color.Color}> {message}</color>";
    
    public static string WithRealTime(this string message) => $"[RealTime:{DateTime.Now}] {message}";
    
    public static string WithGameTime(this string message) => $"[GameTime:{Time.time}] {message}";
    
    public static string WithDelta(this string message) => $"[Delta:{Time.deltaTime}] {message}";
    
    public static string WithFrame(this string message) => $"[Frame:{Time.frameCount}] {message}";
}

public struct LogColor
{
    public readonly string Color;

    private LogColor(string color)
    {
        Color = color;
    }
    
    public static readonly LogColor Red = new LogColor("#FF0000");
    public static readonly LogColor Tomato = new LogColor("#FF6347");
    public static readonly LogColor Orange = new LogColor("#FFA500");
    public static readonly LogColor Skin = new LogColor("#FFDAB9");
    public static readonly LogColor Yellow = new LogColor("#FFFACD");
    public static readonly LogColor Green = new LogColor("#4EEE94");
    public static readonly LogColor Cyan = new LogColor("#00EEEE");
    public static readonly LogColor Blue = new LogColor("#87CEFA");
    public static readonly LogColor Purple = new LogColor("#9370DB");
    public static readonly LogColor Pink = new LogColor("#FFAEB9");
    public static readonly LogColor Gray = new LogColor("#A2B5CD");
}